javascript element by class

86

get element by class name -

var y = document.getElementsByClassName('foo');
var aNode = y[0];

Comments

Submit
0 Comments